<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="utf-8">
<!-- qtimageformats.qdoc -->
  <title>Qt Image Formats 5.14.2</title>
  <link rel="stylesheet" type="text/css" href="style/offline-simple.css" />
  <script type="text/javascript">
    document.getElementsByTagName("link").item(0).setAttribute("href", "style/offline.css");
    // loading style sheet breaks anchors that were jumped to before
    // so force jumping to anchor again
    setTimeout(function() {
        var anchor = location.hash;
        // need to jump to different anchor first (e.g. none)
        location.hash = "#";
        setTimeout(function() {
            location.hash = anchor;
        }, 0);
    }, 0);
  </script>
</head>
<body>
<div class="header" id="qtdocheader">
  <div class="main">
    <div class="main-rounded">
      <div class="navigationbar">
        <table><tr>
<td ><a href="../qtdoc/index.html">Qt 5.14</a></td><td >Qt Image Formats</td></tr></table><table class="buildversion"><tr>
<td id="buildversion" width="100%" align="right">Qt 5.14.2 Reference Documentation</td>
        </tr></table>
      </div>
    </div>
<div class="content">
<div class="line">
<div class="content mainContent">
<div class="sidebar">
<div class="toc">
<h3><a name="toc">Contents</a></h3>
<ul>
<li class="level1"><a href="#the-image-i-o-plugins">The Image I/O Plugins</a></li>
<li class="level2"><a href="#deployment">Deployment</a></li>
<li class="level2"><a href="#licenses-and-attributions">Licenses and Attributions</a></li>
<li class="level2"><a href="#security-considerations">Security considerations</a></li>
</ul>
</div>
<div class="sidebar-content" id="sidebar-content"></div></div>
<h1 class="title">Qt Image Formats</h1>
<span class="subtitle"></span>
<!-- $$$qtimageformats-index.html-description -->
<div class="descr"> <a name="details"></a>
<p>The core Qt Gui library by default supports reading and writing image files of the most common file formats: <code>PNG</code>, <code>JPEG</code>, <code>BMP</code>, <code>GIF</code> and a few more, ref. <a href="../qtgui/qimage.html#reading-and-writing-image-files">Reading and Writing Image Files</a>. The Qt Image Formats add-on module provides optional support for other image file formats.</p>
<p>The file format support is provided transparently, through plugins for Qt's image I/O system. As such, this module provides no API of its own. Instead, the functionality is accessed in the same way as other image I/O in Qt: through <a href="../qtgui/qimage.html#load">QImage::load</a>() and <a href="../qtgui/qimage.html#save">QImage::save</a>(). Or, for more detailed control, through <a href="../qtgui/qimagereader.html">QImageReader</a> and <a href="../qtgui/qimagewriter.html">QImageWriter</a>.</p>
<a name="the-image-i-o-plugins"></a>
<h2 id="the-image-i-o-plugins">The Image I/O Plugins</h2>
<p>The actual coding and decoding of the file format is done by a codec library. The codec can be Qt or third party code. In case of a third party codec, the build process will look for it among the system libraries. If not found, it may fall back on using a bundled copy (in <code>src/3rdparty</code>).</p>
<div class="table"><table class="generic">
 <thead><tr class="qt-style"><th >Format</th><th >Description</th><th >Support</th><th >3rd Party Codec</th></tr></thead>
<tr valign="top" class="odd"><td >ICNS</td><td >Apple Icon Image</td><td >Read/write</td><td >No</td></tr>
<tr valign="top" class="even"><td >JP2</td><td >Joint Photographic Experts Group 2000</td><td >Read/write</td><td >Yes (Not bundled)</td></tr>
<tr valign="top" class="odd"><td >MNG</td><td >Multiple-image Network Graphics</td><td >Read</td><td >Yes (Not bundled)</td></tr>
<tr valign="top" class="even"><td >TGA</td><td >Truevision Graphics Adapter</td><td >Read</td><td >No</td></tr>
<tr valign="top" class="odd"><td >TIFF</td><td >Tagged Image File Format</td><td >Read/write</td><td >Yes (bundled)</td></tr>
<tr valign="top" class="even"><td >WBMP</td><td >Wireless Bitmap</td><td >Read/write</td><td >No</td></tr>
<tr valign="top" class="odd"><td >WEBP</td><td >WebP</td><td >Read/write</td><td >Yes (bundled)</td></tr>
</table></div>
<p><b>Note: </b>Some bundled third party codecs are not maintained anymore. They are provided for manual builds only, and not used as a fallback in case system libraries are unavailable.</p><p><b>Note: </b>For security reasons, the Direct Draw Surface (DDS) handler is not built by default since Qt 5.8&#x2e; Users who still want this handler can build it from the source project.</p><a name="deployment"></a>
<h3 id="deployment">Deployment</h3>
<p>When built, the Qt Image Formats plugins are located as dynamic libraries in the runtime plugin directory (typically <code>plugins/imageformats</code>), together with the default image format plugins. They may be deployed to the target system in the same way as other plugins, see the <a href="../qtdoc/deployment-plugins.html">Deploying Plugins</a> documentation.</p>
<a name="licenses-and-attributions"></a>
<h3 id="licenses-and-attributions">Licenses and Attributions</h3>
<p>Qt Image Formats is available under commercial licenses from <a href="http://www.qt.io/about-us/">The Qt Company</a>. In addition, it is available under the <a href="http://www.gnu.org/licenses/lgpl-3.0.html">GNU Lesser General Public License, version 3</a>, or the <a href="http://www.gnu.org/licenses/gpl-2.0.html">GNU General Public License, version 2</a>. See <a href="../qtdoc/licensing.html">Qt Licensing</a> for further details.</p>
<p>Furthermore Qt Image Formats potentially contains third party modules under following permissive licenses:</p>
<div class="table"><table class="annotated">
<tr class="odd topAlign"><td class="tblName"><p><a href="qtimageformats-attribution-libtiff.html">TIFF Software Distribution (libtiff), version 4.1&#x2e;0</a></p></td><td class="tblDescr"><p>libtiff License</p></td></tr>
<tr class="even topAlign"><td class="tblName"><p><a href="qtimageformats-attribution-libwebp.html">WebP (libwebp), version 1.0&#x2e;3</a></p></td><td class="tblDescr"><p>BSD 3-clause &quot;New&quot; or &quot;Revised&quot; License</p></td></tr>
</table></div>
<a name="security-considerations"></a>
<h3 id="security-considerations">Security considerations</h3>
<p>Since these file formats are more rarely used, the codecs may be less thoroughly debugged against potential security holes. As always, care should be taken when creating applications that may be used to decode uncontrolled data files.</p>
</div>
<!-- @@@qtimageformats-index.html -->
        </div>
       </div>
   </div>
   </div>
</div>
<div class="footer">
   <p>
   <acronym title="Copyright">&copy;</acronym> 2020 The Qt Company Ltd.
   Documentation contributions included herein are the copyrights of
   their respective owners.<br/>    The documentation provided herein is licensed under the terms of the    <a href="http://www.gnu.org/licenses/fdl.html">GNU Free Documentation    License version 1.3</a> as published by the Free Software Foundation.<br/>    Qt and respective logos are trademarks of The Qt Company Ltd.     in Finland and/or other countries worldwide. All other trademarks are property
   of their respective owners. </p>
</div>
</body>
</html>
